package com.zhou.dao;

import com.zhou.pojo.User;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;


import java.util.List;

public interface IUserDao {
    @Select("select * from userinfo ")
    public List<User> findAll();

    @Select("select * from userinfo where id = #{id}")
    public User findById(int id);

    @Update("update userinfo set age=#{age}, username=#{username}, password=#{password}, email=#{email}, sex=#{sex} where id= #{id} ")
    public void update(User user);
}
